
import logging
import yagmail
# 日志
def log_set():
    logging.basicConfig(level=logging.DEBUG,format='%(name)s_%(levelno)s_%(levelname)s',handlers=[
        logging.StreamHandler(),
        logging.FileHandler('log.txt')
    ])
# 报告
def send_mail(a):
    mail=yagmail.SMTP(user='2164156101@qq.com',password='rcsxpgtpjmiadjbi',host='smtp.qq.com')
    mail.send(to='2164156101@qq.com',subject='测试报告主题',contents='测试报告内容',attachments=a)
